package com.tedu.egvehicle1.pojo.dto;

import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.Email;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Pattern;
import jakarta.validation.constraints.Size;
import lombok.Data;

@Data
public class UserRegParam {
    @NotNull
    @Size(min = 6,max = 10,message = "用户名信息必须在6-10位之间")
    @Schema(description = "用户名",required = true)
    private String username;
//    @Pattern(regexp = "(?=.*[A-Za-z])(?=.*[\\d!@#$%^&*()_+{}\\\":;'<>?,.\\/\\-=|])(?!.*[\\s\\u4e00-\\u9fa5])[A-Za-z\\d!@#$%^&*()_+{}\\\":;'<>?,.\\/\\-=|]{8,14}",message = "密码格式不合法")
    @Schema(description = "密码",required = true)
    private String password;
    @Schema(description = "邮箱",required = true)
    @Email(message = "邮箱格式不合法")
    private String email;
    @Schema(description = "手机号",required = true)
    private String phone;
}
